#include"Vector.h"


int main()
{
    std::cout << "A case:" << std::endl;
    Vector<int> v;
    v.push_back(1);
    v.push_back(2);
    for (const auto& m : v) {
        std::cout << m << " ";
    }
    std::cout << std::endl;
    v.pop_back();
    for (const auto& m : v) {
        std::cout << m << " ";
    }
    std::cout << std::endl;
    std::cout << std::endl;


    std::cout << "A case:" << std::endl;
    Vector<char> ch;
    ch.push_back('q');
    ch.push_back('w');
    for (const auto& n : ch) {
        std::cout << n << " ";
    }
    ch.pop_back();
    std::cout << std::endl;
    for (const auto& n : ch) {
        std::cout << n << " ";
    }
    std::cout << std::endl;
    std::cout << std::endl;

    std::cout << "A case:" << std::endl;
    Vector<int> e(2, 1);
    e.push_back(5);
    e.push_back(1);
    e.push_back(4);
    e.print();
    e.insert(2, 4);
    for (const auto& m : e) {
        std::cout << m << " ";
    }
    std::cout << std::endl;
    e.swap(3, 4);
    for (const auto& m : e) {
        std::cout << m << " ";
    }
    std::cout << std::endl;
    e.find(5);
    e.change(2, 3);
    for (const auto& m : e) {
        std::cout << m << " ";
    }
    std::cout << std::endl;
    e.reverse();
    for (const auto& x : e) {
        std::cout << x << " ";
    }
    std::cout << std::endl;
    e.erase(2);
    for (const auto& x : e) {
        std::cout << x << " ";
    }
    std::cout << std::endl;
    e.resize(20);
    std::cout << "Size is " << e.Size() << std::endl;
    std::cout << std::endl;

    return 0;
}
